package cn.wolfcode.wolf2world.service;

import cn.wolfcode.wolf2world.domain.Banner;
import cn.wolfcode.wolf2world.query.BannerQueryObject;
import org.springframework.data.domain.Page;

import java.util.List;

/**
 * @author 杨兴健
 * @Date 2020/8/19 18:30
 */
public interface BannerService {
    Banner get(String id);
    void insert(Banner banner);
    void update(Banner banner);
    void delete(String id);

    List<Banner> list();

    Page<Banner> query(BannerQueryObject qo);

    /**
     * 保存/更新
     * @param banner
     */
    void saveOrUpdate(Banner banner);

    /**
     * 根据类型查询
     * @param typeTravel
     * @return
     */
    List<Banner> findByType(int typeTravel);
}
